<?php include __DIR__ . "/../../php/db.php"; ?>

<!DOCTYPE html>
<head>
	<title>Experience</title>
	<meta name="keywords" content="" />
	<meta name="description" content="" />
	<meta charset="UTF-8">
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<link href="http://fonts.googleapis.com/css?family=Open+Sans:300,400,700" rel="stylesheet" type="text/css">
	<link href="css/font-awesome.min.css" rel="stylesheet" type="text/css">
	<link href="css/bootstrap.min.resume.css" rel="stylesheet" type="text/css">
	<link href="css/bootstrap-theme.min.css" rel="stylesheet" type="text/css">
	<link href="css/resumestyle.css" rel="stylesheet" type="text/css">	
    	<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>

<?php

$login = $_SESSION['login'];

$userid = mysql_query("SELECT * FROM `flss`.`accounts` WHERE `user` = '$login'") or die(mysql_error());
while($rowshow = mysql_fetch_array($userid))
{
	$getid = $rowshow['account_id'];
}

if(isset($_POST['add']))
{
	header("Refresh:0");
	
}

if(isset($_POST['save']))
{
	$today = date('d');
	$cname = $_POST['cname'];
	$cadd = $_POST['country'];
	$from = $_POST['yearD'].'-'.$_POST['monthD'].'-'.$today;
	$to = $_POST['yearT'].'-'.$_POST['monthT'].'-'.$today;
	$level = $_POST['plevel'];
	$xpdesc = $_POST['exp'];
	$ptitle = $_POST['position'];
	$explevel = $_POST['explevel'];
	mysql_query("INSERT INTO `a_experience`(`applicant_id`, `companyname`, `companyadd`, `Fromdate`, `Todate`, `explevel`, `positionlevel`, `expdescription`, `positiontitle`) 
	VALUES ('$getid','$cname','$cadd','$from','$to','$explevel','$level','$xpdesc','$ptitle')");
	}

?>
</head>
<body class="templatemo-bg-gray">
	<div class="container" style="overflow-x:hidden;">
		<div class="col-md-12">	
			<h1 class="text-center margin-bottom-15">Experience</h1>		
			<form class="form-horizontal templatemo-contact-form-2 templatemo-container"  method="post">
				<div class="row">
						<div class="col-md-12 form-group" style="padding-left: 30px;">				         				         
					         <div class="templatemo-inline-group">
					         	<div class="col-sm-12 templatemo-select-container">
					         		<select name="explevel" id="text6" style="width: 552px; height: 32px; padding-left:20px;">
									    <option selected="" disabled="">Experience Level</option>
	  									<option value="Have Been Employed">Have Been Employed</option>
	  									<option value="Fresh Graduate">Fresh Graduate</option>
	  									<option value="Student seeking Interniship/Part-Time Job">Student seeking Interniship/Part-Time Job</option>
	  								</select>
					         		</div>
								</div>
				    		</div>				         				         
				    	</div>
                  <div class="row">
					<div class="col-md-6">
						<div class="form-group">				          		          	
				           	<div class="col-sm-12">
				            	<div class="templatemo-input-icon-container">
				            		<input type="text" name="position" class="form-control" id="name" placeholder="Position Title" style="width: 643px;">
				            	</div>		            		            		            
				          	</div>              
				        </div>
				      </div>
				  </div>
				   <div class="row">
					<div class="col-md-6" style="width: 365px;">
						<div class="col-md-12 form-group">				         				         
					         <div class="templatemo-inline-group">
					         	<div class="col-sm-12 templatemo-select-container" style="width:380px;">
					         		<label class="control-label">Duration</label> &nbsp; &nbsp;  
					         		<label class="control-label"><b>FROM</b></label> &nbsp; &nbsp; &nbsp;
									  <select name="monthD" id="text16" style="height: 32px;width: 80px;">
									  <option selected="" disabled="">Month</option>
									   <option value="01">January</option>
									   <option value="02">February</option>
									   <option value="03">March</option>
									   <option value="04">April</option>
									   <option value="05">May</option>
									   <option value="06">June</option>
									   <option value="07">July</option>
									   <option value="08">August</option>
									   <option value="09">September</option>
									   <option value="10">October</option>
									   <option value="11">November</option>
									   <option value="12">December</option>
									  </select>
									  <input type="text" placeholder="Year" name="yearD" id="text17" style="height: 32px; width: 120px;">
									  
									
					         	</div>
							</div>
				    	</div>
				      </div>
					<div class="col-md-6" style="width: 365px;">
						<div class="col-md-12 form-group">				         				         
					         <div class="templatemo-inline-group">
					         	<div class="col-sm-12 templatemo-select-container" style="width:350px;">
					         		<label class="control-label"><b>TO</b></label> &nbsp; &nbsp; &nbsp; 
									  <select name="monthT" id="text16" style="height: 32px;width: 80px;">
									  <option selected="" disabled="">Month</option>
									   <option value="01">January</option>
									   <option value="02">February</option>
									   <option value="03">March</option>
									   <option value="04">April</option>
									   <option value="05">May</option>
									   <option value="06">June</option>
									   <option value="07">July</option>
									   <option value="08">August</option>
									   <option value="09">September</option>
									   <option value="10">October</option>
									   <option value="11">November</option>
									   <option value="12">December</option>
									  </select>
									  <Input type="text" placeholder="Year" name="yearT" id="text17" style="height: 32px; width: 120px;">
					         	</div>
							</div>
				    	</div>
				      </div>
				     </div>
				  <div class="row">
					<div class="col-md-6">
						<div class="form-group">				          		          	
				           	<div class="col-sm-12">
				            	<div class="templatemo-input-icon-container">
				            		<input type="text" name="cname" class="form-control" id="name" placeholder="Company Name" style="width: 643px;">
				            	</div>		            		            		            
				          	</div>              
				        </div>
				      </div>
				      <div class="row">
					<div class="col-md-6" style="left: 200px;width: 180px;">
						<div class="col-md-12 form-group">				         				         
					         <div class="templatemo-inline-group">
					         	<div class="col-sm-12 templatemo-select-container">
					         		<input type="text" placeholder="Country" name="country" id="text6" style="height: 32px;">
									     
					         	</div>
							</div>
				   		 </div>
				 	 </div>
				  </div>
				</div>
				    <div class="row">
						<div class="col-md-12 form-group" style="padding-left: 30px;">				         				         
					         <div class="templatemo-inline-group">
					         	<div class="col-sm-12 templatemo-select-container">
					         		<select name="plevel" id="text6" style="width: 552px; height: 32px; padding-left:20px;">
									<option selected disabled>Position Level</option>
    								<option value="CEO / SVP / AVP / VP/Director">CEO / SVP / AVP / VP/Director</option>
   									 <option value="Assistant Manager/Manager">Assistant Manager/Manager</option>
   									 <option value="Supervisor / 5 years and Up Experienced">Supervisor / 5 years and Up Experienced</option>
   									 <option value="1-4 years Experience">1-4 years Experience</option>
   									 <option value="Non-Executive">Non-Executive</option>
   							 		</select>
					         		</div>
								</div>
				    		</div>
					 <div class="col-md-6">
						<div class="form-group">
				          <div class="col-md-12">
				            <div class="templatemo-input-icon-container">
				            	<textarea class="form-control" name="exp" id="message" placeholder="Experience Description" style="width: 644px; min-height: 34px;height: 114px;"></textarea>
				          </div>
				        </div>
				     </div>				         				         
				   </div>
				  </div>
                  
		        <div class="form-group">
		          <div class="col-md-12">
		            <input type="submit" value="SAVE" name="save" class="btn btn-warning pull-right">
					<input type="submit" name="add"  value="ADD EXPERIENCE" class="btn btn-warning pull-right" style="margin-right:10px;">		            
		          </div>
		        </div>		    	
		      </form>	
 
              
		</div>
	</div>
</body>
</html>